package com.financing.wap.dao.impl;

import java.util.List;
import com.financing.wap.dao.impl.BaseDaoImpl;
import com.financing.wap.dao.IFpFundManagerDao;
import com.financing.wap.dto.FpFundManagerDTO;
import com.financing.wap.util.SqlName;

import org.springframework.stereotype.Repository;

/**
 * @Description:实现类
 * @author caojiayao
 * @version 1.0
 * @created 
 */
@Repository("fpFundManager")
public class FpFundManagerDaoImpl extends BaseDaoImpl implements IFpFundManagerDao {
	
	@Override
	public FpFundManagerDTO getFpFundManager(FpFundManagerDTO dto) {
		return (FpFundManagerDTO)this.getSqlMapClientTemplate().queryForObject(SqlName.fpFundManager,dto);
	}
	
	
	@Override
	public Integer insertFpFundManager(FpFundManagerDTO dto) {
		return (Integer) this.getSqlMapClientTemplate().insert(SqlName.insertFpFundManager,dto);
	}

	
	@Override
	public Integer updateFpFundManager(FpFundManagerDTO dto) {
		return (Integer) this.getSqlMapClientTemplate().update(SqlName.updateFpFundManager, dto);
	}
	
	@Override
	public Integer delFpFundManager(Integer id) {
		return (Integer) this.getSqlMapClientTemplate().delete(SqlName.delFpFundManager, id);
	}
	
	@Override
	public List<FpFundManagerDTO> listFpFundManager(FpFundManagerDTO dto) {
		return (List<FpFundManagerDTO>)this.getSqlMapClientTemplate().queryForList(SqlName.listFpFundManager, dto);
	}
	
	
	public Integer countFpFundManager(FpFundManagerDTO dto){
		return (Integer)this.getSqlMapClientTemplate().queryForObject(SqlName.countFpFundManager, dto);
	}
	
	
	public List<FpFundManagerDTO> listFpFundManagerByCompanyId(String companyId){
		return (List<FpFundManagerDTO>)this.getSqlMapClientTemplate().queryForList(SqlName.listFpFundManagerByCompanyId, companyId);
	}
	
	public List<FpFundManagerDTO> listFpFundManagerByFundId(String FundId){
		return (List<FpFundManagerDTO>)this.getSqlMapClientTemplate().queryForList(SqlName.listFpFundManagerByFundId, FundId);
	}
	
	@Override
	public Class<FpFundManagerDTO> getEntityClass() {
		return FpFundManagerDTO.class;
	}
}
